Boundary conduction mode switching regulator and driver circuit and control method thereof

ABSTRACT

A boundary conduction mode (BCM) switching regulator controls a power stage to convert an input voltage to an output voltage or output current. The BCM switching regulator detects whether it is operating in continuous conduction mode (CCM) or discontinuous conduction mode (DCM), and adjusts the On-time, Off-time, or frequency of the power stage accordingly, so that the switching regulator operates in or near BCM.

CROSS REFERENCE

The present invention claims priority to U.S. provisional applicationNo. 61/240,057, filed on Sep. 4, 2009.

The present application is a continuation application of U.S. Ser. No.12/848,480, filed on Aug. 2, 2010.

BACKGROUND OF THE INVENTION

1. Field of Invention

The present invention relates to a switching regulator, a switchingregulator driver circuit, and a switching regulator control method;particularly, it relates to a switching regulator which is controlled tooperate in or near boundary conduction mode (BCM), and a driver circuitand a control method which operate a switching regulator in or near BCM.

2. Description of Related Art

FIG. 1 shows the circuitry of a typical switching regulator, in which aPWM (pulse width modulation) controller 11 controls one or more powertransistors in a power stage circuit 12, to convert an input voltage Vinto an output voltage Vout or output current lout. The power stagecircuit 12 may be, but is not limited to, asynchronous or asynchronousbuck, boost, inverting or buck-boost converter as shown in FIGS. 2A-2H.Back to FIG. 1, a feedback circuit 13 generates a feedback signalrelating to the output voltage Vout or the output current lout and sendsthe feedback signal to the PWM controller 11 so that the PWM controller11 can control the power stage circuit 12 to regulate the output voltageVout or the output current lout to a desired target.

FIG. 3 shows a switching regulator which generates two output voltagesVout1 and Vout2, with two feedback control circuits: the first feedbackcircuit 13A and the second feedback circuit 13B. The power stage circuit12 in this case may be, but is not limited to, a synchronous orasynchronous inverting-boost converter as shown in FIGS. 4A and 4B.

FIGS. 5A-5C show three operation modes of a switching regulator, takingthe asynchronous boost switching regulator of FIG. 2D as an example. Asshown in FIG. 5A, in continuous conduction mode (CCM), the powertransistor is turned ON before the inductor current I(L) decreases tozero. This causes larger switching loss and higher EMI (electro-magneticinterferences), especially in high voltage applications. Indiscontinuous conduction mode (DCM) as shown in FIG. 5C, to supplyrequired power to the output, it requires a higher peak current andtherefore it requires a power transistor with higher current rating,causing higher conduction power loss.

Therefore, in many applications, it is best to operate the switchingregulator in boundary conduction mode (BCM) as shown in FIG. 5B.

In view of the foregoing, the present invention provides a switchingregulator which is controlled to operate in or near BCM, and a switchingregulator driver circuit and a switching regulator control method tooperate a switching regulator in or near BCM.

SUMMARY OF THE INVENTION

The first objective of the present invention is to provide a switchingregulator which is controlled to operate in or near boundary conductionmode (BCM).

The second objective of the present invention is to provide a drivercircuit for controlling a switching regulator to operate in or near BCM.

The third objective of the present invention is to provide a controlmethod for controlling a switching regulator to operate in or near BCM.

To achieve the objectives mentioned above, from one perspective, thepresent invention provides a switching regulator for converting an inputvoltage to an output voltage or output current, wherein the switchingregulator is capable of operating in CCM, DCM, or BCM which is betweenCCM and DCM, the switching regulator comprising: a power stage includingat least one power transistor which switches according to a PWM signalto convert the input voltage to the output voltage or output current; amode detector coupling to the power stage for detecting the conductionmode in which the switching regulator is operating, and generating amode signal indicating whether the switching regulator is operating inDCM or CCM; a feedback circuit generating a feedback signal according tothe output voltage or output current; a control signal generatorgenerating a control signal according to the mode signal; and a PWMcontroller generating the PWM signal according to the feedback signal,and adjusting On-time, Off-time, or frequency of the PWM signalaccording to the control signal, such that the switching regulatoroperates in or near BCM.

From another perspective, the present invention provides a switchingregulator driver circuit, wherein the switching regulator is forconverting an input voltage to an output voltage or output current, andis capable of operating in CCM, DCM, or BCM which is between CCM andDCM, the switching regulator driver circuit comprising: a mode detectorcoupling to a power stage of the switching regulator, for detecting theconduction mode in which the switching regulator is operating, andgenerating a mode signal indicating whether the switching regulator isoperating in DCM or CCM; a control signal generator generating a controlsignal according to the mode signal; and a PWM controller generating aPWM signal to control the conversion of the input voltage to the outputvoltage or output current according to a feedback signal related to theoutput voltage or output current, wherein On-time, Off-time, orfrequency of the PWM signal is adjusted according to the control signalsuch that the switching regulator operates in or near BCM.

In the aforementioned switching regulator or switching regulator drivercircuit, the power transistor is electrically connected between a fixedlevel and a variable level node, and in one embodiment, the modedetector detects a voltage level of the variable level node to determinewhether the switching regulator is operating in DCM.

In one embodiment of the present invention, the mode detector includes alow pass filter for filtering the voltage of the variable level node togenerate a filtered signal; and a DCM feature detection circuit fordetecting whether the filtered signal has a DCM feature and generatingthe mode signal accordingly.

Optionally, the DCM feature detection circuit may further include ade-glitch circuit coupled to the logic gate to de-glitch a noise.

In the aforementioned switching regulator or switching regulator drivercircuit, in one embodiment, the PWM controller includes an oscillatorwith an oscillating frequency determined by the control signal. Or, inanother embodiment, the PWM controller includes an On-time timer or anOff-time timer which determines the On-time or Off-time of the PWMsignal according to the control signal.

In the aforementioned switching regulator or switching regulator drivercircuit, in one embodiment, the control signal generator includes: acapacitor; a charge and discharge circuit, for charging and dischargingthe capacitor according to the mode signal; a transistor having acontrolled end, a current inflow end, and a current outflow end, whereinthe controlled end is controlled by the capacitor voltage, and a currentis generated at the current inflow end; and a resistor coupled to thecurrent outflow end, wherein the control signal is the current generatedat the current inflow end or a voltage at the current outflow end.

In another embodiment, the control signal generator includes an up/downcounter, receiving a clock signal and counting according to the modesignal to generate a count number. The control signal generator mayfurther include a digital to analog converter for converting the countnumber to an analog signal, and the analog signal may be used as thecontrol signal.

From yet another perspective, the present invention provides a controlmethod for controlling a switching regulator, wherein the switchingregulator is for converting an input voltage to an output voltage oroutput current, and is capable of operating in CCM, DCM, or BCM which isbetween CCM and DCM, the control method comprising: detecting theconduction mode in which the switching regulator is operating, andgenerating a mode signal indicating whether the switching regulator isoperating in DCM or CCM; generating a control signal according to themode signal; and adjusting On-time, Off-time, or frequency of the PWMsignal according to the control signal such that the switching regulatoroperates in or near BCM.

Optionally, the aforementioned control method may further include:operating the switching regulator in or near BCM in normal condition,but not in any one or more of the conditions below: (1) when the outputcurrent of the switching regulator reaches an upper limit; (2) when theswitching frequency of the power transistor reaches an upper limit; (3)when the switching frequency of the power transistor reaches a lowerlimit; or (4) when the output current of the switching frequency islower than a lower limit.

Optionally, the aforementioned control method may further include:providing two or more control modes, in one of the control mode theswitching regulator operates in or near BCM; and selecting one of thecontrol modes to be the control mode of the switching regulator.

The objectives, technical details, features, and effects of the presentinvention will be better understood with regard to the detaileddescription of the embodiments below.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 shows a prior art circuitry of a typical switching regulator.

FIGS. 2A-2H shows synchronous or asynchronous buck, boost, inverting orbuck-boost converters.

FIG. 3 shows a prior art switching regulator which generates two outputvoltages Vout1 and Vout2, with two feedback control circuits.

FIGS. 4A-4B shows a synchronous and an asynchronous inverting-boostconverters.

FIGS. 5A-5C shows signal waveforms of three operation modes of aswitching regulator.

FIG. 6 shows an embodiment of the present invention.

FIG. 7 shows an embodiment of the control signal generator 16.

FIG. 8 shows another embodiment of the control signal generator 16.

FIG. 9 shows one example of the CCM and DCM signal waveforms.

FIG. 10A shows a schematic diagram of the low pass filter 142.

FIG. 10B shows an embodiment of the low pass filter 142.

FIG. 11 shows the waveforms of the filtered signal V(SW_LPF) in CCM andDCM, respectively.

FIG. 12 shows an embodiment of the mode detector 14.

FIG. 13 shows an embodiment of the DCM feature detection circuit 144.

FIG. 14 shows the signal waveforms of the circuit of FIG. 13 in CCM/BCMand DCM.

FIG. 15 shows how the circuit of FIG. 7 works.

FIG. 16 shows another embodiment of the present invention.

FIGS. 17-21 show that the switching regulator of the present inventionis not limited to operating in BCM, but also can operate in a mixedcontrol mode. Each of the figures shows a relationship between the load(output) current and the switching frequency by an illustrative curve.

FIG. 22 shows that the switching regulator of the present invention canoperate in a dual control mode.

DESCRIPTION OF THE PREFERRED EMBODIMENTS

One key concept of the present invention is to detect the conductionmode of a switching regulator, and to control the switching regulatoraccordingly such that the switching regulator operates in or near BCM.Thus, the switching loss and EMI can be reduced, and it does not requirea high current rating power transistor, so there is less conductionpower loss.

FIG. 6 shows one embodiment of the present invention. As shown in thisfigure, the switching regulator of the present invention includes adriver circuit 100, a power stage circuit 12, and a feedback circuit 13.The driver circuit 100 includes a PWM controller 11 which controls atleast one power transistor of the power stage circuit 12 to convert aninput voltage Vin to an output voltage Vout or output current lout. Thefeedback circuit 13 generates a feedback signal relating to the outputvoltage Vout or the output current lout and sends the feedback signal tothe PWM controller 11 so that the PWM controller 11 can control thepower stage circuit 12 to regulate the output voltage Vout or the outputcurrent lout to a desired target. According to the present invention,the pulse width (On-time pulse width or Off-time pulse width) andfrequency of the PWM signal generated by the PWM controller 11 can beadjusted (either or both of pulse width and frequency can be adjusted),such that the switching regulator can operate in or near BCM. Thedetails of the adjustment will be depicted later.

One characteristic of the present invention is that the driver circuit100 includes a BCM control circuit 110. The BCM control circuit 110includes a mode detector 14 and a control signal generator 16. The modedetector 14 detects the mode in which the switching regulator isoperating, and generates a mode signal “DCM_Y”, i.e, a signal indicatingwhether the switching regulator is operating in DCM or CCM. The controlsignal generator 16 receives this mode signal DCM_Y, and generates acontrol signal “FC” to control the frequency of an oscillator 112 in thePWM controller 11. The oscillator 112 can be a voltage controlledoscillator with a frequency adjustable by voltage or a currentcontrolled oscillator with a frequency adjustable by current. Incorrespondence, the control signal FC can be a voltage signal or acurrent signal. The voltage controlled oscillator and current controlledoscillator are both well known circuits, so they are not redundantlyexplained in detail here. Referring to FIG. 5A-5C, as shown in FIG. 5A,when the switching regulator is operating in CCM, it means that thepower transistor is turned ON before the inductor current I(L) decreasesto zero, i.e., too early before it can reach BCM. Thus, if the frequencyis adjusted lower (the period is adjusted longer while the duty ratiokeeps unchanged), or the On-time or the Off-time is increased, theoperation will move from CCM towards DCM. Likewise, as shown in FIG. 5C,when the switching regulator is operating in DCM, it means that thepower switch is turned ON too late after it passes BCM; thus, if thefrequency is adjusted faster (the period is adjusted shorter while theduty ratio keeps unchanged), or the On-time or the Off-time isdecreased, the operation will move from DCM towards CCM.

FIG. 7 shows one embodiment of the control signal generator 16. Thecontrol signal generator 16 includes a charge and discharge circuit 162,a capacitor C, a transistor Q, and a resistor R, wherein the transistorQ can be a bipolar junction transistor (BJT) or a metal oxidesemiconductor field effect transistor (MOSFET). In this embodiment, aBJT is shown as an example. The charge and discharge circuit 162includes a first current source CS1, a second current source CS2, and aswitch circuit; the switch circuit switches according to the mode signalDCM_Y to determine whether the capacitor C is charged with a firstconstant current I1 by the first current source CS1, or discharged witha second constant current I2 through the current source CS2, whereinI1>>I2. The charge and discharge of the capacitor C determines a voltageVB which is the voltage of the controlled end of the transistor Q (basevoltage when the transistor Q is a BJT, and gate voltage when thetransistor Q is a MOSFET). In this embodiment, either the collectorcurrent FC(I) or the emitter voltage FC(V), which is generated by thetransistor Q according to the base voltage VB, can be used as thecontrol signal FC for controlling the frequency of the oscillator 112(depending on whether the oscillator 112 is voltage controlled orcurrent controlled), wherein the emitter voltage FC(V) is approximatelyequal to the base voltage VB minus 0.7V (VB-0.7V), and the emittercurrent (roughly equal to the collector current) is the emitter voltageof the transistor Q divided by the resistance of the resistor R. If thetransistor Q is a MOSFET, either the source voltage or the currentobtained by the source voltage divided by the resistance of the resistorR can be used as the control signal FC.

FIG. 8 shows another embodiment of the control signal generator 16. Asshown in this figure, an up/down counter 166 counts up or down accordingto the mode signal DCM_Y, and a digital to analog converter (DAC) 168converts the count to the control signal FC for controlling theoscillator 112. Or, as another embodiment, the DAC 168 or a circuit witha function equivalent to digital to analog conversion can be integratedinto the oscillator 112, and in such case, the up/down counter 166 cancontrol the frequency of the oscillator 112 directly by its digitaloutput (i.e., the control signal FC is a digital signal in this case).

The conduction mode of the switching regulator may be detected byvarious ways; the key is to distinguish the difference between thesignal waveforms in CCM and DCM. As an example, referring to FIG. 9, thepower transistor of the power stage 12 is coupled between a fixed leveland a variable level node SW (referring to, e.g., FIG. 2D). The signalV(SW) is the voltage at the node SW in FIG. 2D. The signals V(SW) in CCMand DCM are clearly distinguishable one from the other. As anotherexample for conduction mode detection, referring to FIGS. 10A and 11,the signals V (SW) in CCM and DCM can be filtered by a low pass filter(LPF) 142, and the resultant signals V (SW_LPF) in CCM and DCM stillpresent distinguishable features. The low pass filter 142 can be, but isnot limited to, the circuit as shown in FIG. 10B.

Referring to FIG. 12, the mode detector 14 for example may include thelow pass filter 142 and a DCM feature detection circuit 144. The lowpass filter 142 receives the signal V (SW) and generates the signal V(SW_LPF). The DCM feature detection circuit 144 receives the signal V(SW_LPF) and detects whether there is a DCM feature in the signal. Inone embodiment, this may be achieved by a circuit as shown in FIG. 13.Referring to both FIGS. 13 and 14, a comparator 1441 shown in FIG. 13compares the signal V (SW_LPF) with a reference voltage Vdet. Thefeature of the DCM signal V (SW_LPF) will cause the output Det_Out ofthe comparator 1441 to go high earlier than in the case of CCM. Thus,the mode signal DCM_Y can be generated by detecting this earlierresponse. Shown as an example is the use of an inverted signal of a gatesignal V(Gate)

(referring to FIG. 2D), as a shielding signal. The gate signal V(gate)and the output signal Det_Out are inputted to an AND gate 1442. Thus,the output signal of the AND gate 1442 may be used as the mode signalDCM_Y, which present a waveform as shown in FIG. 14. There are otherways to process the comparator 1441 output Det_Out, as long as thedifference between CCM and DCM can be identified. A de-glitch circuit1443 may optionally be provided in the embodiment of FIG. 13.Furthermore, by adjusting the parameters of the de-glitch circuit 1443or the delay time of the comparator 1441, or by other equivalent ways, adesigner can adjust the pulse width of the signal DCM_Y, such that theswitching regulator may operate not in exact BCM but slightly toward DCMor slightly toward CCM.

FIG. 15 explains how the circuit of FIG. 7 works according to the signalDCM_Y generated by the circuit of FIG. 13. As shown in FIG. 15, becausethe charge current (first constant current) I1>>the discharge current(second constant current) I2, the base voltage VB of the control signalgenerator 16 is a step signal with an ascending slope, as shown in thisfigure. Accordingly, the collector current FC(I) or the emitter voltageFC(V) will also be a step signal with ascending slope, and can be usedas the control signal FC. The step-widths of the step signals in FIG. 15are exaggerated for better illustration; they should be very small inpractical implementations, which can be achieved by using a largercapacitor C and/or smaller current sources CS1 and CS2.

FIG. 16 shows another embodiment wherein the present invention isapplied to a constant ON-time or constant OFF-time scheme. In thisembodiment, the control signal generator 16 generates a signal “TC” tocontrol the ON-time or OFF-time timer 114 in the PWM controller 11, andthe PWM controller 11 controls the ON-time or OFF-time of a power switchin the power stage 12. When the switching regulator is operating in CCM,the control signal TC increases the On-time or the Off-time, and whenthe switching regulator is operating in DCM, the control signal TCdecreases the On-time or the Off-time. The control signal TC may be thesame signal as the control signal FC in the aforementioned FIGS. 7-15,or a digital signal outputted from the up/down counter 16 in FIG. 8,that is, the circuits and schemes of the embodiments in FIGS. 7-15 canbe applied in this embodiment, except that the control signal outputtedfrom the control signal generator 16 controls time instead of frequency.The details of the timer 114 are not redundantly explained here becausea timer which can be set to count different periods of time is wellknown.

FIG. 17 shows the relationship between the load (output) current and theswitching frequency. If the switching regulator operates in CCM, itoperates above the curve; in DCM, it operates under the curve; in BCM,it operates exactly on the curve. The two arrows a and b illustrate thefeature of this invention to adjust the switching frequency toward theBCM curve, such that the switching regulator operates in or near BCM.Similarly, in the constant ON-time or constant Off-time control schemes,this invention will increase the ON-time or Off-time if the switchingregulator operates in CCM, and decrease the ON-time or Off-time if theswitching regulator operates in DCM, to adjust operation of theswitching regulator toward the BCM curve.

Although the present invention proposes a method to operate theswitching regulator in BCM, the switching regulator does not have tooperate only in BCM, but instead may operate in a combination ofmultiple modes. For example, FIG. 18 shows a mixed mode, i.e., BCM withcurrent limit (such as over-current protection). The curve in thisfigure shows that the switching regulator normally operates in BCM, butwhen the load (output) current reaches the current limit, the switchingregulator is forced to operate in DCM. This mixed mode can be embodiedby the over-current protection circuit shown at the left side of thisfigure. When the over-current protection circuit detects the outputcurrent lout and finds that it exceeds a predetermined upper limit Iref,the comparator outputs an over-current protection signal OCP to maintainthe output current Iout below the predetermined upper limit.

FIG. 19 shows another mixed mode, i.e., BCM with frequency upper andlower limit. The frequency is limited within a range may be for thereason to avoid the audible frequency or to decrease switching loss. Thecurve in this figure shows that the switching regulator normallyoperates in BCM, but when the switching frequency reaches the upperfrequency limit, the switching regulator is forced to operate in DCM;when the switching frequency reaches the lower frequency limit, theswitching regulator is forced to operate in CCM. This mixed mode can beembodied by setting the frequency upper and lower limit of theoscillator. An oscillator typically includes a capacitor and charge anddischarge current sources, so the frequency upper and lower limit of theoscillator can be set by providing upper and lower limits to thecurrents charging and discharging the capacitor.

FIG. 20 shows another mixed mode, i.e., BCM with pulse skipping mode,burst mode, or other frequency reduction mode (the pulse skipping modeand burst mode are shown in the lower part of the drawing). The curve inFIG. 20 shows that the switching regulator normally operates in BCM, butwhen the load (output) current becomes smaller than a predeterminedthreshold, the switching regulator reduces its switching frequency. Thefrequency reduction is shown to be linear in the figure but it is onlyan example. It can be non-linear.

The pulse skipping mode, burst mode, or other frequency reduction modefor example can be achieved by a masking circuit 18 selectively maskingthe output signal of the PWM controller 11.

FIG. 21 shows a relatively complex mixed mode, which is a combination ofBCM, current limit, frequency limit, and frequency reduction.

Furthermore, a switching regulator according to the present inventioncan operate in dual-mode or multiple-mode, that is, the switchingregulator provides two or more control modes as options, and a user canselect one of the two or more control modes for the switching regulatorto operate in. For example, as shown in FIG. 22, the switching regulatorprovides two control modes, for example BCM and fixed frequency PWM asshown in the figure, one of which is determined to be the operation modeof the switching regulator by a user or by a microcontroller circuit.

The control schemes shown in FIG. 18-22 can be further combined withother control modes or further modified as desired; the BCM switchingregulator of the present invention can include many other functions, oralternatively, the BCM control circuit 110 of the present invention canbe added into switching regulators with such functions. All these shouldbe included within the scope of the present invention.

The present invention has been described in considerable detail withreference to certain preferred embodiments thereof. It should beunderstood that the description is for illustrative purpose, not forlimiting the scope of the present invention. Those skilled in this artcan readily conceive variations and modifications within the spirit ofthe present invention. First, the term “operate in” or “stay at” BCMshould not mean that the switching regulator must precisely operateexactly in, or stay exactly at BCM without any tolerance; instead, theyshould mean that the switching regulator may operate with an acceptabledeviation from BCM. Second, the foregoing embodiments detect whether theswitching regulator is operating in DCM and adjust the frequency,On-time, or Off-time accordingly, but they can certainly be modified todetecting whether the switching regulator is operating in CCM.Furthermore, the mode detector 14 and the control signal generator 16are not limited to two separate circuits; instead, they may beintegrated to one circuit. For another example, a circuit or devicewhich does not substantially influence the primary function of a signal,such as a switch or the like, can be inserted between any two devices orcircuits in the shown embodiments. The meanings of high and low levelsof a digital signal may be interchanged. For example, the positive andnegative input terminals of the comparator 1441 in FIG. 13 areinterchangeable, and the AND gate 1442 may be modified to another logiccircuit, with corresponding amendment to the circuit for processingthese signals. These and other modifications should be interpreted tofall within the scope of the present invention.

1-16. (canceled)
 17. A control method for controlling a switchingregulator, wherein the switching regulator is for converting an inputvoltage to an output voltage or output current according to a PWMsignal, and is capable of operating in continuous conduction mode (CCM),discontinuous conduction mode (DCM), or boundary conduction mode (BCM)which is between CCM and DCM, the control method comprising: detectingthe conduction mode in which the switching regulator is operating, andgenerating a mode signal indicating whether the switching regulator isoperating in DCM or CCM; generating a control signal according to themode signal; and adjusting On-time, Off-time, or frequency of the PWMsignal according to the control signal such that the switching regulatoroperates in or near BCM, wherein when the switching regulator isoperating in DCM, the control signal reduces the On-time or Off-time ofthe PWM signal, or increases the frequency of the PWM signal, such thatthe operation of the switching regulator moves from relatively fartherto relatively closer to BCM; and when the switching regulator isoperating in CCM, the control signal increases the On-time or Off-timeof the PWM signal, or reduces the frequency of the PWM signal, such thatthe operation of the switching regulator moves from relatively fartherto relatively closer to BCM.
 18. The control method of claim 17, whereinwhen the switching regulator is operating in DCM, reduces the On-time orOff-time of the PWM signal, or increases the frequency of the PWMsignal; when the switching regulator is operating in CCM, increases theOn-time or Off-time of the PWM signal, or reduces the frequency of thePWM signal, such that the switching regulator operates in or near BCM.19. The control method of claim 17, wherein the power transistor iselectrically connected between a fixed level and a variable level node,and the step of detecting the mode in which the switching regulator isoperating includes: determining whether the switching regulator isoperating in DCM according to a voltage level of the variable levelnode.
 20. The control method of claim 17 further includes: operating theswitching regulator in or near BCM in normal condition, but not in anyone or more of the conditions below: (1) when the output current of theswitching regulator reaches an upper limit; (2) when the switchingfrequency of the power transistor reaches an upper limit; (3) when theswitching frequency of the power transistor reaches a lower limit; or(4) when the output current of the switching frequency is lower than alower limit.
 21. The control method of claim 17 further including:providing two or more control modes, in one of the control mode theswitching regulator operates in or near BCM; and selecting one of thecontrol modes to be the control mode of the switching regulator.
 22. Aswitching regulator for converting an input voltage to an output voltageor output current, wherein the switching regulator is capable ofoperating in continuous conduction mode (CCM), discontinuous conductionmode (DCM), or boundary conduction mode (BCM) which is between CCM andDCM, the switching regulator comprising: a power stage including atleast one power transistor which switches according to a pulse widthmodulation (PWM) signal to convert the input voltage to the outputvoltage or output current; a mode detector coupling to the power stagefor detecting the conduction mode in which the switching regulator isoperating, and generating a mode signal indicating whether the switchingregulator is operating in DCM or CCM; a feedback circuit generating afeedback signal according to the output voltage or output current; acontrol signal generator generating a control signal according to themode signal; and a PWM controller generating the PWM signal according tothe feedback signal, and adjusting On-time, Off-time, or frequency ofthe PWM signal according to the control signal, such that the switchingregulator operates in or near BCM, wherein when the switching regulatoris operating in DCM, the control signal reduces the On-time or Off-timeof the PWM signal, or increases the frequency of the PWM signal, suchthat the operation of the switching regulator moves from relativelyfarther to relatively closer to BCM; and when the switching regulator isoperating in CCM, the control signal increases the On-time or Off-timeof the PWM signal, or reduces the frequency of the PWM signal, such thatthe operation of the switching regulator moves from relatively fartherto relatively closer to BCM.
 23. The switching regulator of claim 22,wherein the power transistor is electrically connected between a fixedlevel and a variable level node, and the mode detector detects a voltagelevel of the variable level node to determine whether the switchingregulator is operating in DCM.
 24. The switching regulator of claim 22,wherein the PWM controller includes: an oscillator with an oscillatingfrequency determined by the control signal.
 25. The switching regulatorof claim 22, wherein the PWM controller includes: an On-time timer or anOff-time timer, determining the On-time or Off-time of the PWM signalaccording to the control signal.
 26. A switching regulator drivercircuit, wherein the switching regulator is for converting an inputvoltage to an output voltage or output current, and is capable ofoperating in continuous conduction mode (CCM), discontinuous conductionmode (DCM), or boundary conduction mode (BCM) which is between CCM andDCM, the switching regulator driver circuit comprising: a mode detectorcoupling to a power stage of the switching regulator, for detecting theconduction mode in which the switching regulator is operating, andgenerating a mode signal indicating whether the switching regulator isoperating in DCM or CCM; a control signal generator generating a controlsignal according to the mode signal; and a PWM controller generating aPWM signal to control the conversion of the input voltage to the outputvoltage or output current according to a feedback signal related to theoutput voltage or output current, wherein when the switching regulatoris operating in DCM, the control signal reduces the On-time or Off-timeof the PWM signal, or increases the frequency of the PWM signal, suchthat the operation of the switching regulator moves from relativelyfarther to relatively closer to BCM; and when the switching regulator isoperating in CCM, the control signal increases the On-time or Off-timeof the PWM signal, or reduces the frequency of the PWM signal, such thatthe switching regulator operates in or near BCM, such that the operationof the switching regulator moves from relatively farther to relativelycloser to BCM.
 27. The driver circuit of claim 26, wherein the PWMcontroller includes: an oscillator with an oscillating frequencydetermined by the control signal.
 28. The driver circuit of claim 26,wherein the PWM controller includes: an On-time timer or an Off-timetimer, determining the On-time or Off-time of the PWM signal accordingto the control signal.
 29. The driver circuit of claim 26, wherein thecontrol signal generator includes: an up/down counter, receiving a clocksignal and counting according to the mode signal to generate a countnumber.